package com.github.tetrisgame.model;

import android.content.Context;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;

import com.github.tetrisgame.utils.BitmapUtils;

public class GridModel {
    private int resId = 0;

    //构造方法
    public GridModel(int resId){
        this.resId = resId;
    }

    //判断是否为空
    public boolean hasData(){
        return resId != 0;
    }

    //获取资源图片
    public Bitmap getBitmap(){
        return BitmapUtils.defaultUtils.getBitmap(resId);
    }
}
